{% load map_icons %}
<div id="location-info-container">
    <div class="location-address">
        <strong>{{ location.town }}</strong>, {{ location.region.name }} <br />
        <small>{{ location.address }}</small>
    </div>

    <div class="location-items">
    {% for base_station in items %}
        <div class="location-item">
            <img src="{{ base_station|get_icon }}" class="location-network-icon pull-left" />
            <strong>{{ base_station.network.name }}</strong>
            {% if base_station.station_id %}
                <small>ID: <abbr title="Identyfikator wewnętrzny operatora">{{ base_station.station_id }}</abbr></small>
            {% endif %}
            {% if base_station.is_networks %}
                <small>(<abbr title="Stacja będąca częścią NetWorks!">N!</abbr>)</small>
            {% endif %}<br/>
            {% if base_station.location_details != '' and base_station.location_details|lower != location.address|lower %}
                <small>{{ base_station.location_details }}</small><br/>
            {% endif %}

            {% comment %}
            {% if base_station.location_details != location.address %}
                <br/><small>{{ base_station.location_details }}</small>
            {% endif %}
            {% endcomment %}

            {% with base_station.get_supported_standards_and_bands as supported %}
                {% if supported %}
                    <small>
                        {% for support in supported %}
                            {{ support.standard }}{{ support.band }}
                        {% endfor %}
                        <a class="location-info" href="{% url 'bts:bts-extended-info-view' base_station.id %}" class="pull-right">Szczegóły...</a>
                    </small>
                {% endif %}
            {% endwith %}
        </div>
    {% endfor %}
    </div>

    <div class="location-info-footer">
        <small>GPS: {{ location.latitude }},{{ location.longitude }})</small>
        {% if request.user.is_staff %}
        <br/><small>ID: <a href="{% url 'panel:location-edit-view' location.id %}">{{ location.id }}</a></small>
        {% endif %}
    </div>
</div>
